import { request } from '@/api/request'

const baseURL = window.globalData.baseUrl
/* 网格 */
export const governmentLayer = function (data) {
    return request({
        'baseURL': baseURL,
        'url': '/enforcement/superviseLayer/list',
        'method': 'post',
        data: data
    })
}
/*党员信息 */
export const getPartyMemberList = function (data) {
    return request({
        'baseURL': baseURL,
        'url': '/enforcement/party/members',
        'method': 'post',
        data: data
    })
}
/* 图层 */
export const getHomeEventLayer = function (data) {
    return request({
        'baseURL': baseURL,
        'url': '/enforcement/superviseLayer/list',
        'method': 'post',
        data: data
    })
}

/* 获取单兵点位信息 */
export const getsimpleSoldier = function (data) {
    return request({
        'baseURL': baseURL,
        'url': '/enforcement/command/simpleSoldier/list',
        'method': 'post',
        data: data
    })
}

/* 获取视频点位信息 */
export const getVideoPosition = function (data) {
    return request({
        'baseURL': baseURL,
        'url': '/dataTrans/video/position?areaName=' + data,
        'method': 'get'
        // data: data
    })
}

/* 获取AR点位信息 */
export const getARPosition = function (data) {
    return request({
        'baseURL': baseURL,
        'url': '/dataTrans/video/ar/position',
        'method': 'post',
        data: data
    })
}
/* 车辆 */
export const getvehicle = function () {
    return request({
        'baseURL': baseURL,
        'url': '/enforcement/command/vehicle/list',
        'method': 'post'
    })
}

/* 首页事件 */
export const geteventHandler = function (data) {
    return request({
        'baseURL': baseURL,
        'url': '/governance/layer/homepage/event',
        'method': 'post',
        data: data
    })
}
/* 公共管理事件 */
export const geteventHandler2 = function () {
    return request({
        'baseURL': baseURL,
        'url': '/governance/layer/untreated/event',
        'method': 'post'
    })
}
/* 小区点位信息 */
export const getgoodsBuilding = function () {
    return request({
        'baseURL': baseURL,
        'url': '/livelihood/village/list',
        'method': 'get',
        params: {
            type: 'goodsBuilding'
        }
    })
}

/* 得到河道信息 */
export const getriverdetail = function (id) {
    return request({
        'baseURL': baseURL,
        'url': '/enforcement/river/detail',
        'method': 'post',
        data: {
            'river_id': id
        }
    })
}

/* 获取小区楼层信息 */
export const storiedFloor = function (params) {
    return request({
        'baseURL': baseURL,
        'url': '/livelihood/village/layer/floor',
        'method': 'post',
        data: params
    })
}

/* 获取小区栋数接口 */

export const floorbuildinglist = function (data) {
    return request({
        'baseURL': baseURL,
        'url': '/livelihood/village/building/list',
        'method': 'post',
        data: data
    })
}
/* 楼宇 */
export const storiedHouse = function (data) {
    return request({
        'baseURL': baseURL,
        'url': '/livelihood/village/house/list',
        'method': 'post',
        data: data
    })
}

/* 准备会议 */
export const createSession = function (data) {
    return request({
        'baseURL': baseURL,
        'url': '/enforcement/meeting/invitation',
        'method': 'post',
        data: data
    })
}

/* 关闭会议 */
export const exitSession = function () {
    return request({
        'baseURL': baseURL,
        'url': '/enforcement/meeting/close',
        'method': 'post',
        data: {
            'river_id': id
        }
    })
}

/* 视频树/dataTrans/video/completeTree*/
export const equipmentSearch = function () {
    return request({
        'baseURL': baseURL,
        'url': '/dataTrans/video/completeTree',
        'method': 'post',
        data: {}
    })
}

/* 获取网格信息 */
export const getwanggeJson = function () {
    return request({
        'baseURL': baseURL,
        'url': '/enforcement/wg/list',
        'method': 'get'
    })
}